<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        div {
            width: 200px;
            height: 200px;
            background-color: pink;
        }
        

    </style>
</head>
<body>
    <div>
        1
    </div>
    <a href="#">2222</a>
    <ul>
        <li>1111</li>
        <li>222</li>
        <li>2333</li>
    </ul>
    <script>
        var div  = document.querySelector('div')
        div.addEventListener('click',function(e){
                 console.log(e.target);
                 console.log(this);
                 
                 
        })
        var ul  = document.querySelector('ul')
        ul.addEventListener('click',function(e){
            console.log(this);
            console.log(e.target);
            console.log(e.type);
            
            
            
        },true)
         var a = document.querySelector('a')
         a.addEventListener('click',function(e){
                //   e.preventDefault() 阻止事件的默认行为
                // 低版本浏览器 e.returnValue
                // return false
         })
    </script>
</body>
</html>